package com.warren.blog.test;

/**
 * @author warren
 *     @Override
 *     public StringBuilder append(String str) {
 *         super.append(str);
 *         return this;
 *     }
 * 链式写法的原理就是返回了this
 */
public class testChainWriting {
    public static void main(String[] args) {
        StringBuilder hello = new StringBuilder();
        hello.append("warren").append("-").append("18");
        System.out.println(hello);
    }
}
